﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
using Wix.Aura.Common.CustomTypes;

namespace Wix.Aura.Common {
	public class Interface : IXmlSerializable {
		private Interface() { }
		public Interface(Guid id, string name) {
			Id = id;
			Name = name;
		}

		public Guid Id { get; set; }
		public Guid? BaseInterface { get; set; }
		public string Name { get; set; }
		public int? NumMethods { get; set; }
		public Guid? ProxyStubClassId { get; set; }
		public Guid? ProxyStubClassId32 { get; set; }
		public YesNoType Versioned { get; set; }

		public System.Xml.Schema.XmlSchema GetSchema() {
			throw new NotImplementedException();
		}

		public void ReadXml(System.Xml.XmlReader reader) {
			throw new NotImplementedException();
		}

		public void WriteXml(System.Xml.XmlWriter writer) {
			writer.WriteStartElement("Interface");
			writer.WriteAttribute("Id", Id);
			writer.WriteAttribute("BaseInterface", BaseInterface);
			writer.WriteAttribute("Name", Name);
			writer.WriteAttribute("NumMethods", NumMethods);
			writer.WriteAttribute("ProxyStubClassId", ProxyStubClassId);
			writer.WriteAttribute("ProxyStubClassId32", ProxyStubClassId32);
			writer.WriteAttribute("Versioned", Versioned);
			writer.WriteEndElement();
		}
	}
}
